<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title></title>
    <style>
        canvas{border: 1px solid red;}
    </style>
</head>
<body>
<canvas id="box" width="1800" height="1800"></canvas>
<script>
    var box=document.getElementById("box");
    var pen=box.getContext("2d");
    pen.rect(100,100,100,100);
    pen.scale(3,3);
    pen.rect(100,100,100,100);
    pen.stroke();
    pen.beginPath();
    pen.arc(300,300,50,0,Math.PI*2,true);
    pen.closePath();
    pen.stroke();

</script>
</body>
</html>